﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="WebQueryRole.Login" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <link href="styles/style.css" rel="Stylesheet" type="text/css" />    
    <title></title>
    <% if(justLoggedIn && !String.IsNullOrEmpty(Request["url"])) {
            Response.Write("<META HTTP-EQUIV=\"refresh\" CONTENT=\"3;URL=" + Request["url"] + "\">");
       } %>
</head>
<body>
    <form id="form1" runat="server">
    <div>    
    <div id="informationDiv"><%=infoMessage %></div>
    <% if (adminMode)
       { %>
       <h2> Create User </h2>
        New User <input type="text" name="create-username" /> <br />
        New Password <input type="text" name="create-password" /> <br />
        <input type="submit" name="submit" value="create" />            
    <% } else if(!loginState.IsLoggedIn) { %>       
        <h2> Login Credentials </h2>        
        User <input type="text" name="username" /> <br />
        Password <input type="password" name="password" /> <br />
        <input type="submit" name="submit" value="login" />        
    <% } %>
    </div>
    </form>
</body>
</html>
